Constant Length Insertion Tool (CLIT) v1.0 (03/26/01)

anusp / Brian Maxwell
maxwellb@home.com

J2e Translations!
www.j2etranslations.com

-----------------------------------------------------------

This is a simple utility written by anusp to insert constant length
text into a rom.  This program uses a config file to get information
such as what source file to use, how long the names are,
and other important stuff!


What do I mean by constant length?

Constant length text is text such as item names or character names
in a game that is stored at certain lengths apart without any separators
in between each name. (By separator i mean a tag like 00 or FF that normally
signifies the end of a text string in a game).




HOW TO USE THE PROGRAM


1. Set Up The Config File
First you must edit clit.cfg (or whatever you want to call it) to meet the
specifications required for your specific game.

Here is how to edit the config file.

********************************
CLIT CONFIG FILE

// this will get the text file with the names that need to be inserted
i=input.txt;

// this will tell the program what file to dump the output to
o=output.out;

// this will tell the program what file contains the font table for the game
t=table.dat;

// this tells the program how long each name is
l=16;


@end_of_file - DO NOT REMOVE THIS LINE


// NOTE: each of these lines in the config file MUST have a ';' after it in order to work!
// NOTE: the maximum size of data to output is 65536 bytes so watch your n= value and the number of items you input
// NOTE: you can call the file names whatever you like.. but them must have an 8 letter maximum with a 3 letter extension


// if the '@' is not present the program will crash or freeze!
// have a nice day :)

*************************************


2. Edit Your Font Table

you can open up "sample.tbl" using a hex editor or a text editor for an example of
the format the font table needs to be in.

basically this is how it works.

in a text editor such as notepad you would have something that looks like this:

"                                _                                abcdefghijklmnopqrstuvwxyz      ABCDEFGHIJKLMNOPQRSTUVWXYZ                                                                                                                                     "

without the quotation marks of course-- that is just to show you what is in the file
the font table file has to be exactly 256 bytes in size


here is an easier way to visualize how this works

                                _                                abcdefghijklmnopqrstuvwxyz      ABCDEFGHIJKLMNOPQRSTUVWXYZ                                                                                                                                     
0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef...
0               1               2               3               4               4               6               7

The numbers along the bottom represents what the letters are going to be in the
game.  So the letter "a" is at position 41. that means that "a" in your text file
will become the hex value 0x41, and "Z" would become 0x7A, and so on..

You will also notice at 0x20 there is a "_".  That is what you must use to tell
the program that a space is being used. So any time it sees a space in the text file
it will use 0x20 for the space when being inserted.



3. Run The Program

At the command prompt type "clit clit.cfg" and viola! your output.out will be created!
The advantage to calling the cfg file through the command line lets you have
mulitple config files for different game, or perhaps different parts of the same
game!








Any questions, bug reports, comments, complaints, or I didn't make this
readme clear enough then email me!


Thanks,

anusp
